//调用接口配置文件
import { request } from 'config/request'
import {config } from 'config/config'
export async function queryAllAddress(params) {
    return request({
        url: 'admin/address/queryAllAddress',
        method: 'GET',
        data: params,
    });
};

export async function getroleList(params) {
    return request({
        url: "admin/permissionAdmin/getAllRole",
        method: 'GET',
        headers: {
            "Content-type": "application/json"
        },
        data: params
    });
};
//保存编辑用户
export async function createUser(params){
    return request({
        url:'admin/login/create',
        method:'POST',
        headers:{
            "Content-type":'application/json'
        },
        data:params
    })
}
//保存编辑用户
export async function updateUser(params){
    return request({
        url:'admin/permissionAdmin/update',
        method:'POST',
        headers:{
            "Content-type":'application/json'
        },
        data:params
    })
}
//获取用户信息
export async function getUserDetail(params){
    return request({
        url:'admin/permissionAdmin/detail',
        method:'POST',
        headers:{
            "Content-type":'application/json'
        },
        data:params
    })
}

export async function queryAddressList(params) {
    return request({
      url: '3rd/commission/getRegion',
      method: 'GET',
      data: params,
    });
  };
